Setting the Font Style

You can use the font-style property to set the font style of the text present on an HYML Web page. This property allows you to format your text in different styles, such as bold, italics, and underlined. For example, using this property, you can italicize a text on which you want to emphasize. This could be a new term or a word from other language.

Let’s do the following steps to set font style of the text present on an HTML Web page:


<!DOCTYPE html>
<html>
<head>
<title>Setting the Font Style</title>
    <style type=”text/css”>
    p {font-style: normal; font-size: 25px}
    div {font-style: italic; font-size: large;}
    </style>
</head>
<body>
    <p>This is normal text.</p>
    <div>This text is italicize. </div>
</body>
</html> 

Save the document with the name FontStyle.html and open on browser.